#include <stdio.h>
#include <string.h>
int main() {
  char s[101];
  scanf("%s", s);
  int len = strlen(s), count = 1, max = 0;
  for (int i = 1; i < len; i++)
    if (s[i] == s[i - 1]) {
      count++;
    } else {
      max = count > max ? count : max;
      count = 1;
    }
  max = count > max ? count : max;
  printf("%s\n", max >= 7 ? "YES" : "NO");
  return 0;
}